package com.crois.barrier.common.response;

import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;

/**
 * @author Hou Ze Yu
 * @description
 * @date 2020/10/23
 */
@NoArgsConstructor
@AllArgsConstructor
public enum BarrierResponseStatus {
    SUCCESS(200,"请求成功"),
    FAIL(500,"请求失败"),
    BAD_ARGUMENT(5402,"参数不正确"),
    INTERNAL_ERROR(5503,"系统异常稍后再试"),
    BAD_PARAMETER_FORMAT(5504,"参数格式异常"),
    PATH_NOT_MATH(504,"路径不正确"),
    BAD_GATEWAY(502,"网关服务异常"),
    REGISTER_FAIL(516,"注册失败"),
    SERVER_NOT_USE(526,"当前服务不可用"),
    SERVER_DEGRADE(528,"服务被降级"),
    LOGIN_FAIL(517,"登陆失败"),
    LOGOUT_FAIL(5117,"退出失败"),
    SERVER_FLOW(527,"请求频繁，稍后再试"),
    UN_AUTH(506,"无权限操作"),
    DO_FAIL(5066,"操作失败"),
    UPDATE_FAIL(5507,"更新失败"),
    DELETE_FAIL(5509,"删除失败"),
    QUERY_FAIL(5602,"查询失败"),
    ADD_FAIL(5602,"添加失败");
    private int code;
    private String message;

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
